home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Bank smakow / BankSmakow.air / BankSmakow.swf / scripts / com / makingwaves / controller / Controller.as
Text File  |  2009-12-16  |  2KB  |  40 lines

  1. package com.makingwaves.controller
  2. {
  3.    import com.adobe.cairngorm.control.FrontController;
  4.    import com.makingwaves.commands.LoadDataCommand;
  5.    import com.makingwaves.commands.LoadLocalDataCommand;
  6.    import com.makingwaves.commands.ResetProductsCommand;
  7.    import com.makingwaves.commands.SelectAllCommand;
  8.    import com.makingwaves.commands.SelectNewCommand;
  9.    import com.makingwaves.commands.SelectProductCommand;
  10.    import com.makingwaves.events.LoadDataEvent;
  11.    import com.makingwaves.events.LoadLocalDataEvent;
  12.    import com.makingwaves.events.ResetProductsEvent;
  13.    import com.makingwaves.events.SelectAllEvent;
  14.    import com.makingwaves.events.SelectNewEvent;
  15.    import com.makingwaves.events.SelectProductEvent;
  16.    
  17.    public class Controller extends FrontController
  18.    {
  19.       
  20.       private static var UUID:String = "bd346566-4e58-441a-9a2a-08d3d56cc480";
  21.        
  22.       
  23.       public function Controller()
  24.       {
  25.          super();
  26.          initialiseCommands();
  27.       }
  28.       
  29.       private function initialiseCommands() : void
  30.       {
  31.          addCommand(SelectProductEvent.EVENT_NAME,SelectProductCommand);
  32.          addCommand(LoadDataEvent.EVENT_NAME,LoadDataCommand);
  33.          addCommand(LoadLocalDataEvent.EVENT_NAME,LoadLocalDataCommand);
  34.          addCommand(ResetProductsEvent.EVENT_NAME,ResetProductsCommand);
  35.          addCommand(SelectNewEvent.EVENT_NAME,SelectNewCommand);
  36.          addCommand(SelectAllEvent.EVENT_NAME,SelectAllCommand);
  37.       }
  38.    }
  39. }
  40.